//package test.my.com.myapplicationtest.holder_dapter;
//
//import android.content.Context;
//import android.support.v7.widget.RecyclerView;
//import android.util.SparseArray;
//import android.view.LayoutInflater;
//import android.view.View;
//import android.view.ViewGroup;
//import android.widget.Button;
//import android.widget.FrameLayout;
//import android.widget.ImageView;
//import android.widget.LinearLayout;
//import android.widget.RelativeLayout;
//import android.widget.TextView;
//
//import java.util.List;
//
///**
// * Author : Cooper
// * Time : 2016/12/7  11:13
// * Description : 封装RecyclerView.Adapter
// */
//public class RecyclerViewHolderAdapter<T> extends RecyclerView.Adapter<RecyclerViewHolderAdapter.MyViewHolder> {
//
//    private Context mContext;
//    private List<T> mDateList;
//
//    public RecyclerViewHolderAdapter(Context context, List<T> dateList) {
//        this.mContext = context;
//        this.mDateList = dateList;
//    }
//
////    @Override
////    public ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
////        View view = LayoutInflater.from(mContext).inflate(R.layout.item_invest_assistant_list_layout, parent, false);
////        ViewHolder viewHolder = new ViewHolder(view);
////        return viewHolder;
////    }
////
////    @Override
////    public void onBindViewHolder(ViewHolder holder, int position) {
//////        buildViewData(mContext,holder,mDateList.get(position),position);
////    }
//
//    @Override
//    public MyViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
//        View view = LayoutInflater.from(mContext).inflate(R.layout.item_invest_assistant_list_layout, parent, false);
//        MyViewHolder viewHolder = new MyViewHolder(view);
//        return viewHolder;
//    }
//
//    @Override
//    public void onBindViewHolder(MyViewHolder holder, int position) {
//
//    }
//
//    @Override
//    public int getItemCount() {
//        return mDateList!=null?mDateList.size():0;
//    }
//
////    /**
////     * 绑定item的layout
////     * @return
////     */
////    public abstract int buildLayoutView();
////
////    /**
////     * 填充具体数据逻辑
////     * @param holder
////     * @param t
////     * @param position
////     */
////    public abstract void buildViewData(Context context,ViewHolder holder,T t,int position);
//
//    class MyViewHolder extends RecyclerView.ViewHolder{
//
//        public MyViewHolder(View itemView) {
//            super(itemView);
//        }
//    }
////    class MyViewHolder extends RecyclerView.ViewHolder{
////        private final SparseArray<View> mViews;
////        private View mConvertView;
////
////        public MyViewHolder(View itemView) {
////            super(itemView);
////            this.mViews = new SparseArray<>();
////            this.mConvertView = itemView;
////        }
////
////        public <T extends View> T getView(int viewId) {
////
////            View view = mViews.get(viewId);
////            if (view == null) {
////                view = mConvertView.findViewById(viewId);
////                mViews.put(viewId, view);
////            }
////            return (T) view;
////        }
////
////        /**
////         * 获取 TextView
////         * @param viewId
////         * @return
////         */
////        public TextView getTextView(int viewId){
////            return getView(viewId);
////        }
////
////        /**
////         * 获取 ImageView
////         * @param viewId
////         * @return
////         */
////        public ImageView getImageView(int viewId){
////            return getView(viewId);
////        }
////
////        /**
////         * 获取 LinearLayout
////         * @param viewId
////         * @return
////         */
////        public LinearLayout getLinearLayout(int viewId){
////            return getView(viewId);
////        }
////
////        /**
////         * 获取 RelativeLayout
////         * @param viewId
////         * @return
////         */
////        public RelativeLayout getRelativeLayout(int viewId){
////            return getView(viewId);
////        }
////
////        /**
////         * 获取 FrameLayout
////         * @param viewId
////         * @return
////         */
////        public FrameLayout getFrameLayout(int viewId){
////            return getView(viewId);
////        }
////
////        /**
////         * 获取 Button
////         * @param viewId
////         * @return
////         */
////        public Button getButton(int viewId){
////            return getView(viewId);
////        }
////
////        /**
////         * TextView设置文字
////         * @param viewId
////         * @param textViewContent
////         * @return
////         */
////        public TextView setText(int viewId, String textViewContent){
////            TextView textView = getView(viewId);
////            textView.setText(textViewContent);
////            return textView;
////        }
////
////        /**
////         * TextView 设置显示状态
////         * @param viewId
////         * @param visibility
////         * @return
////         */
////        public TextView setTextViewVisibility(int viewId, int visibility){
////            TextView textView = getView(viewId);
////            textView.setVisibility(visibility);
////            return textView;
////        }
////
////        /**
////         * TextView 设置文字颜色
////         * @param viewId
////         * @param textViewColor
////         * @return
////         */
////        public TextView setTextViewColor(int viewId, int textViewColor){
////            TextView textView = getView(viewId);
////            textView.setTextColor(textViewColor);
////            return textView;
////        }
////
////        /**
////         * 设置ImageView背景图片
////         * @param viewId
////         * @param BackgroundId
////         * @return
////         */
////        public ImageView setImageViewBackgroundId(int viewId, int BackgroundId){
////            ImageView imageView = getView(viewId);
////            imageView.setBackgroundResource(BackgroundId);
////            return imageView;
////        }
////
////    }
//}
